/**
 * <copyright>
 * </copyright>
 *
 * $Id$
 */
package org.hl7.v3;

import java.util.Arrays;
import java.util.Collections;
import java.util.List;

import org.eclipse.emf.common.util.Enumerator;

/**
 * <!-- begin-user-doc -->
 * A representation of the literals of the enumeration '<em><b>Insertion</b></em>',
 * and utility methods for working with them.
 * <!-- end-user-doc -->
 * <!-- begin-model-doc -->
 * abstDomain: A14687 (C-0-T14581-A16931-A14687-cpt)
 * <!-- end-model-doc -->
 * @see org.hl7.v3.V3Package#getInsertion()
 * @model extendedMetaData="name='Insertion'"
 * @generated
 */
public enum Insertion implements Enumerator {
	/**
	 * The '<em><b>CERVINS</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #CERVINS_VALUE
	 * @generated
	 * @ordered
	 */
	CERVINS(0, "CERVINS", "CERVINS"),

	/**
	 * The '<em><b>IOSURGINS</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #IOSURGINS_VALUE
	 * @generated
	 * @ordered
	 */
	IOSURGINS(1, "IOSURGINS", "IOSURGINS"),

	/**
	 * The '<em><b>IU</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #IU_VALUE
	 * @generated
	 * @ordered
	 */
	IU(2, "IU", "IU"),

	/**
	 * The '<em><b>LPINS</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #LPINS_VALUE
	 * @generated
	 * @ordered
	 */
	LPINS(3, "LPINS", "LPINS"),

	/**
	 * The '<em><b>PR</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #PR_VALUE
	 * @generated
	 * @ordered
	 */
	PR(4, "PR", "PR"),

	/**
	 * The '<em><b>SQSURGINS</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #SQSURGINS_VALUE
	 * @generated
	 * @ordered
	 */
	SQSURGINS(5, "SQSURGINS", "SQSURGINS"),

	/**
	 * The '<em><b>URETHINS</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #URETHINS_VALUE
	 * @generated
	 * @ordered
	 */
	URETHINS(6, "URETHINS", "URETHINS"),

	/**
	 * The '<em><b>VAGINSI</b></em>' literal object.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @see #VAGINSI_VALUE
	 * @generated
	 * @ordered
	 */
	VAGINSI(7, "VAGINSI", "VAGINSI");

	/**
	 * The '<em><b>CERVINS</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>CERVINS</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #CERVINS
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int CERVINS_VALUE = 0;

	/**
	 * The '<em><b>IOSURGINS</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>IOSURGINS</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #IOSURGINS
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int IOSURGINS_VALUE = 1;

	/**
	 * The '<em><b>IU</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>IU</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #IU
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int IU_VALUE = 2;

	/**
	 * The '<em><b>LPINS</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>LPINS</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #LPINS
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int LPINS_VALUE = 3;

	/**
	 * The '<em><b>PR</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>PR</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #PR
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int PR_VALUE = 4;

	/**
	 * The '<em><b>SQSURGINS</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>SQSURGINS</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #SQSURGINS
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int SQSURGINS_VALUE = 5;

	/**
	 * The '<em><b>URETHINS</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>URETHINS</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #URETHINS
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int URETHINS_VALUE = 6;

	/**
	 * The '<em><b>VAGINSI</b></em>' literal value.
	 * <!-- begin-user-doc -->
	 * <p>
	 * If the meaning of '<em><b>VAGINSI</b></em>' literal object isn't clear,
	 * there really should be more of a description here...
	 * </p>
	 * <!-- end-user-doc -->
	 * @see #VAGINSI
	 * @model
	 * @generated
	 * @ordered
	 */
	public static final int VAGINSI_VALUE = 7;

	/**
	 * An array of all the '<em><b>Insertion</b></em>' enumerators.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private static final Insertion[] VALUES_ARRAY =
		new Insertion[] {
			CERVINS,
			IOSURGINS,
			IU,
			LPINS,
			PR,
			SQSURGINS,
			URETHINS,
			VAGINSI,
		};

	/**
	 * A public read-only list of all the '<em><b>Insertion</b></em>' enumerators.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static final List<Insertion> VALUES = Collections.unmodifiableList(Arrays.asList(VALUES_ARRAY));

	/**
	 * Returns the '<em><b>Insertion</b></em>' literal with the specified literal value.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static Insertion get(String literal) {
		for (int i = 0; i < VALUES_ARRAY.length; ++i) {
			Insertion result = VALUES_ARRAY[i];
			if (result.toString().equals(literal)) {
				return result;
			}
		}
		return null;
	}

	/**
	 * Returns the '<em><b>Insertion</b></em>' literal with the specified name.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static Insertion getByName(String name) {
		for (int i = 0; i < VALUES_ARRAY.length; ++i) {
			Insertion result = VALUES_ARRAY[i];
			if (result.getName().equals(name)) {
				return result;
			}
		}
		return null;
	}

	/**
	 * Returns the '<em><b>Insertion</b></em>' literal with the specified integer value.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public static Insertion get(int value) {
		switch (value) {
			case CERVINS_VALUE: return CERVINS;
			case IOSURGINS_VALUE: return IOSURGINS;
			case IU_VALUE: return IU;
			case LPINS_VALUE: return LPINS;
			case PR_VALUE: return PR;
			case SQSURGINS_VALUE: return SQSURGINS;
			case URETHINS_VALUE: return URETHINS;
			case VAGINSI_VALUE: return VAGINSI;
		}
		return null;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private final int value;

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private final String name;

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private final String literal;

	/**
	 * Only this class can construct instances.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	private Insertion(int value, String name, String literal) {
		this.value = value;
		this.name = name;
		this.literal = literal;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public int getValue() {
	  return value;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public String getName() {
	  return name;
	}

	/**
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	public String getLiteral() {
	  return literal;
	}

	/**
	 * Returns the literal value of the enumerator, which is its string representation.
	 * <!-- begin-user-doc -->
	 * <!-- end-user-doc -->
	 * @generated
	 */
	@Override
	public String toString() {
		return literal;
	}
	
} //Insertion
